<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@ include file="../common/Top.jsp" %>

<div id="BackLink">
    <a href="index.jsp">返回主页面>></a>
</div>

<div id="Login">
    <div class="user-content">
        <div class="user-title">用户登录</div>
        <form action="Login" class="user-form" method="post">
            <c:if test="${requestScope.loginInfo != null}">
                <div class="user-form-error">
                    <i class="fa-solid fa-circle-exclamation error-icon" ></i>
                    <p class="error-msg">${requestScope.loginInfo}</p>
                </div>
            </c:if>
            <div class="user-form-item">
                <input type="text" class="user-form-input" name="userid" id="userid" placeholder="请输入用户名">
                <label for="userid" class="user-form-label" id="useridLabel">
                    <i class="fa-solid fa-user"></i>
                </label>
            </div>
            <div class="user-form-item">
                <input type="password" class="user-form-input" name="password" id="password"autocomplete="off" placeholder="请输入密码">
                <label for="password" class="user-form-label" id="passwordLabel">
                    <i class="fa-solid fa-lock"></i>
                </label>
            </div>
            <div id="checkCodeBox" class="user-form-checkcode">
                <input type="text" class="user-form-check" name="checkcode" id="checkcode" autocomplete="off" placeholder="请输入验证码">
                <label for="checkcode" class="user-form-checklabel" id="checkcodeLabel">
                    <i class="fa-solid fa-lock"></i>
                </label>
                <img id="captcha" src="/Captcha" onclick="reloadCaptcha()">
            </div>
            <div class="user-form-item">
                <input type="submit" class="user-form-submit" value="登录">
            </div>
            <div class="user-form-link">
                <a href="RecoverForm" class="link">忘记密码？</a>
                <a href="RegisterForm" class="link">没有账号？点击前往注册</a>
            </div>
        </form>
        <script type="text/javascript" src="./js/loginPage.js" charset="UTF-8"></script>
    </div>
</div>
<%@ include file="../common/Bottom.jsp" %>
